import Vue from 'vue'
import VueRouter from 'vue-router'
import HelloWorld from '@/components/HelloWorld'
// 1导入VueRouter
// 2通过Vue.use(插件)
// 3创建路由对象
Vue.use(VueRouter)
const routes = [
  {
    path: '/',
    name: 'HelloWorld',
    component: HelloWorld 
  }
]
const router = new VueRouter({
  routes
})

export default router
